﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using DAL;
using Entity;

namespace BLL
{
   public class CpglBLL
    {
        /// <summary>
        /// 插入一条操盘攻略
        /// </summary>
        /// <param name="model"></param>
        /// <returns></returns>
       public bool InsertCpgl(Cpgl model)
       {
           CpglDAL dal = new CpglDAL();
           return dal.InsertCpgl(model);
       }
       /// <summary>
        /// 更新一条记录
        /// </summary>
        /// <param name="model"></param>
        /// <returns></returns>
       public bool Update(Cpgl model)
       {
           CpglDAL dal = new CpglDAL();
           return dal.Update(model);
       }
       /// <summary>
       /// 删除
       /// </summary>
       /// <param name="id"></param>
       /// <returns></returns>
       public bool Delete(int id)
       {
           CpglDAL dal = new CpglDAL();
           return dal.Delete(id);
       }
        /// <summary>
        /// 得到所有的成功启示录
        /// </summary>
        /// <returns></returns>
       public List<Cpgl> GetTop50()
       {
           CpglDAL dal = new CpglDAL();
           return dal.GetTop50();
       }
       public Cpgl GetElementById(int id)
       {
           CpglDAL dal = new CpglDAL();
           return dal.GetElementById(id);
       }

    }
}
